	% run1_transfer_station_data.m

clear

	%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
	% SPECIFY FOLDER 
	%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
folder_input=['./../input/'];
folder_output=['./../output/'];
folder_results=['./../results/'];

	%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
	% LOAD DATA 
	%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
load([folder_input 'datta_final.mat']);

state_names_vec=cell2mat(state_names);
data=[day price_final state uc when_final];
data_string_uno=uno_final;
data_string_zip=zip_final;
data_string_state_names=state_names_vec;

	%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
	% WRITE DATA 
	%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
writematrix(data,[folder_output 'data.txt'],'Delimiter','tab');
writematrix(data_string_uno,[folder_output 'data_string_uno.txt'],'Delimiter','tab','Encoding','UTF-8');
writematrix(data_string_zip,[folder_output 'data_string_zip.txt'],'Delimiter','tab');
writematrix(data_string_state_names,[folder_output 'data_string_state_names.txt'],'Delimiter','tab');

	%
